﻿
@{
    ViewBag.Title = "系统管理";
    Layout = "~/Views/Shared/_Layout_Content.cshtml";
}

<div class="wrapper wrapper-content">
    <div class="ibox float-e-margins">
        <div class="ibox-title">
            <h5>系统设置管理</h5>
            <div class="ibox-tools">
                <a class="collapse-link">
                    <i class="fa fa-chevron-up"></i>
                </a>
            </div>
        </div>
        <div class="ibox-content">
            <button type="button" class="btn btn-primary btn-lg" id="btnReload"><i class="fa fa-undo"></i> 重置路径码</button>
            <button type="button" class="btn btn-danger btn-lg" id="btnReloadTask"><i class="fa fa-undo"></i> 重新加载Hangfire定时任务</button>
            <button type="button" class="btn btn-warning btn-lg" id="btnReloadArea"><i class="fa fa-undo"></i> 重置省市区数据</button>
        </div>
    </div>
</div>
@section scripts
{
    @Scripts.Render("~/content/js/user")
    <script>
        $(function() {
            $("#btnReload").click(function() {
                XPage.DoPost(this, "@Url.Action("ReloadPathCode")", null, null, null);
            });

            $("#btnReloadTask").click(function () {
                XPage.DoPost(this, "@Url.Action("ReloadTasks")", null, null, null);
            });

            $("#btnReloadArea").click(function () {
                XPage.DoPost(this, "@Url.Action("ReInitAreas")", null, null, null);
            });
        });
    </script>
}
